package com.rockcent.mall.lib.dto;

import com.rockcent.common.common.PageResult;
import com.rockcent.common.domain.DtoEntity;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.List;

/**
 * Created by Marco on 16-12-13.
 */
public class MerchantCustomerStatisticsDto extends DtoEntity {

    //YESTERDAY("昨天"), WEEK("最近一周"), MONTH("最近一个月"), QUATER("最近三个月")
    private String searchDateType;

    /**
     * 统计-开始时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private String startDate;

    /**
     * 统计-结束时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private String endDate;

    //总购买客户数
    private Long customerNum;
    //未支付客户
    private Long unpayCustomerNum;
    //支付新客户
    private Long payNewCustomerNum;
    //支付旧客户
    private Long payOldCustomerNum;

    //客户来源列表
    List<MerchantCustomerStatisticsDto> sourceCustomerStatisticsList;
    //活跃客户
    List<MerchantCustomerStatisticsDto> activeCustomerList;
    PageResult<MerchantCustomerStatisticsDto> pageResult;

    //客户来源
    private String sourceType;
    //每日客户来源数
    private Long sourceCustomerNum;
    //客户来源日期
    private String sourceCustomerDate;

    //客户ID
    private Long customerId;
    //客户名称
    private String customerName;
    //联系电话
    private String mobile;
    //累计订单数
    private Long orderNum;
    //购买产品数
    private Long buyNum;
    //已退产品数
    private Long returnNum;
    //累计支付消费额
    private BigDecimal totalAmount;
    //客单价
    private BigDecimal perPrice;
    //总额
    private BigDecimal amount;
    //按小时、天、月
    private String groupByType;

    public String getStartDate() {
        return startDate;
    }

    public void setStartDate(String startDate) {
        this.startDate = startDate;
    }

    public String getEndDate() {
        return endDate;
    }

    public void setEndDate(String endDate) {
        this.endDate = endDate;
    }

    public Long getSourceCustomerNum() {
        return sourceCustomerNum;
    }

    public void setSourceCustomerNum(Long sourceCustomerNum) {
        this.sourceCustomerNum = sourceCustomerNum;
    }

    public String getSourceCustomerDate() {
        return sourceCustomerDate;
    }

    public void setSourceCustomerDate(String sourceCustomerDate) {
        this.sourceCustomerDate = sourceCustomerDate;
    }

    public String getCustomerName() {
        return customerName;
    }

    public void setCustomerName(String customerName) {
        this.customerName = customerName;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public Long getCustomerId() {
        return customerId;
    }

    public void setCustomerId(Long customerId) {
        this.customerId = customerId;
    }

    public Long getOrderNum() {
        return orderNum;
    }

    public void setOrderNum(Long orderNum) {
        this.orderNum = orderNum;
    }

    public Long getBuyNum() {
        return buyNum;
    }

    public void setBuyNum(Long buyNum) {
        this.buyNum = buyNum;
    }

    public Long getReturnNum() {
        return returnNum;
    }

    public void setReturnNum(Long returnNum) {
        this.returnNum = returnNum;
    }

    public Long getCustomerNum() {
        return customerNum;
    }

    public void setCustomerNum(Long customerNum) {
        this.customerNum = customerNum;
    }

    public Long getUnpayCustomerNum() {
        return unpayCustomerNum;
    }

    public void setUnpayCustomerNum(Long unpayCustomerNum) {
        this.unpayCustomerNum = unpayCustomerNum;
    }

    public Long getPayNewCustomerNum() {
        return payNewCustomerNum;
    }

    public void setPayNewCustomerNum(Long payNewCustomerNum) {
        this.payNewCustomerNum = payNewCustomerNum;
    }

    public Long getPayOldCustomerNum() {
        return payOldCustomerNum;
    }

    public void setPayOldCustomerNum(Long payOldCustomerNum) {
        this.payOldCustomerNum = payOldCustomerNum;
    }

    public List<MerchantCustomerStatisticsDto> getSourceCustomerStatisticsList() {
        return sourceCustomerStatisticsList;
    }

    public void setSourceCustomerStatisticsList(List<MerchantCustomerStatisticsDto> sourceCustomerStatisticsList) {
        this.sourceCustomerStatisticsList = sourceCustomerStatisticsList;
    }

    public List<MerchantCustomerStatisticsDto> getActiveCustomerList() {
        return activeCustomerList;
    }

    public void setActiveCustomerList(List<MerchantCustomerStatisticsDto> activeCustomerList) {
        this.activeCustomerList = activeCustomerList;
    }

    public String getSourceType() {
        return sourceType;
    }

    public void setSourceType(String sourceType) {
        this.sourceType = sourceType;
    }

    public BigDecimal getTotalAmount() {
        return totalAmount;
    }

    public void setTotalAmount(BigDecimal totalAmount) {
        this.totalAmount = totalAmount;
    }

    public BigDecimal getPerPrice() {
        return perPrice;
    }

    public void setPerPrice(BigDecimal perPrice) {
        this.perPrice = perPrice;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public String getSearchDateType() {
        return searchDateType;
    }

    public void setSearchDateType(String searchDateType) {
        this.searchDateType = searchDateType;
    }

    public PageResult<MerchantCustomerStatisticsDto> getPageResult() {
        return pageResult;
    }

    public void setPageResult(PageResult<MerchantCustomerStatisticsDto> pageResult) {
        this.pageResult = pageResult;
    }

    public String getGroupByType() {
        return groupByType;
    }

    public void setGroupByType(String groupByType) {
        this.groupByType = groupByType;
    }

    @Override
    public String toString() {
        return "MerchantCustomerStatisticsDto{" +
                "searchDateType='" + searchDateType + '\'' +
                ", startDate='" + startDate + '\'' +
                ", endDate='" + endDate + '\'' +
                ", customerNum=" + customerNum +
                ", unpayCustomerNum=" + unpayCustomerNum +
                ", payNewCustomerNum=" + payNewCustomerNum +
                ", payOldCustomerNum=" + payOldCustomerNum +
                ", sourceCustomerStatisticsList=" + sourceCustomerStatisticsList +
                ", activeCustomerList=" + activeCustomerList +
                ", pageResult=" + pageResult +
                ", sourceType='" + sourceType + '\'' +
                ", sourceCustomerNum=" + sourceCustomerNum +
                ", sourceCustomerDate='" + sourceCustomerDate + '\'' +
                ", customerId=" + customerId +
                ", customerName='" + customerName + '\'' +
                ", mobile='" + mobile + '\'' +
                ", orderNum=" + orderNum +
                ", buyNum=" + buyNum +
                ", returnNum=" + returnNum +
                ", totalAmount=" + totalAmount +
                ", perPrice=" + perPrice +
                ", amount=" + amount +
                ", groupByType='" + groupByType + '\'' +
                '}';
    }
}
